﻿using Aspose.Cells;
using Bentley.Interop.MicroStationDGN;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using static System.Windows.Forms.VisualStyles.VisualStyleElement.ToolTip;

namespace CheccCoverplateCulvertAssemble.Common.Total
{
    /// <summary>
    /// 盖板参数
    /// </summary>
    public class CommonCoverPlateParameter : MyNotifyPropertyChanged
    {
        private FrontPlate _frontPlate = new FrontPlate();
        private SettlementJoint _settlementJoint = new SettlementJoint();
        private LeftInclinedPlate _leftInclinedPlate = new LeftInclinedPlate();
        private RightInclinedPlate _rightInclinedPlate = new RightInclinedPlate();
        public CommonCoverPlateParameter()
        {
        }

        public CommonCoverPlateParameter(FrontPlate frontPlate, SettlementJoint settlementJoint, LeftInclinedPlate leftInclinedPlate, RightInclinedPlate rightInclinedPlate)
        {
            FrontPlate = frontPlate;
            SettlementJoint = settlementJoint;
            LeftInclinedPlate = leftInclinedPlate;
            RightInclinedPlate = rightInclinedPlate;
        }

        public FrontPlate FrontPlate
        {
            get
            {
                return _frontPlate;
            }
            set
            {
                if (value == _frontPlate)
                    return;
                _frontPlate = value;
                NotifyPropertyChanged(() => FrontPlate);
            }
        }

        public SettlementJoint SettlementJoint
        {
            get
            {
                return _settlementJoint;
            }
            set
            {
                if (value == _settlementJoint)
                    return;
                _settlementJoint = value;
                NotifyPropertyChanged(() => SettlementJoint);
            }
        }
        public LeftInclinedPlate LeftInclinedPlate
        {
            get
            {
                return _leftInclinedPlate;
            }
            set
            {
                if (value == _leftInclinedPlate)
                    return;
                _leftInclinedPlate = value;
                NotifyPropertyChanged(() => LeftInclinedPlate);
            }
        }
        public RightInclinedPlate RightInclinedPlate
        {
            get
            {
                return _rightInclinedPlate;
            }
            set
            {
                if (value == _rightInclinedPlate)
                    return;
                _rightInclinedPlate = value;
                NotifyPropertyChanged(() => RightInclinedPlate);
            }
        }
    }
    /// <summary>
    /// 正盖板
    /// </summary>
    public class FrontPlate : MyNotifyPropertyChanged
    {
        private double _length;
        private double _width;
        private double _fulcrumThickness;
        private double _midspanThickness;
        private double _netProtectiveLayer;
        private string _standardPlateModel;
        private string _cellName;
        public FrontPlate()
        {
        }

        public FrontPlate(double length, double width, double fulcrumThickness, double midspanThickness, double netProtectiveLayer, string standardPlateModel, string cellName)
        {
            Length = length;
            Width = width;
            FulcrumThickness = fulcrumThickness;
            MidspanThickness = midspanThickness;
            NetProtectiveLayer = netProtectiveLayer;
            StandardPlateModel = standardPlateModel;
            CellName = cellName;
        }
        /// <summary>
        /// 板长
        /// </summary>
        public double Length
        {
            get
            {
                return _length;
            }
            set
            {
                if (value == _length)
                    return;
                _length = value;
                NotifyPropertyChanged(() => Length);
            }
        }
        /// <summary>
        /// 板宽
        /// </summary>
        public double Width
        {
            get
            {
                return _width;
            }
            set
            {
                if (value == _width)
                    return;
                _width = value;
                NotifyPropertyChanged(() => Width);
            }
        }
        /// <summary>
        /// 支点厚度
        /// </summary>
        public double FulcrumThickness
        {
            get
            {
                return _fulcrumThickness;
            }
            set
            {
                if (value == _fulcrumThickness)
                    return;
                _fulcrumThickness = value;
                NotifyPropertyChanged(() => FulcrumThickness);
            }
        }
        /// <summary>
        /// 跨中厚度
        /// </summary>
        public double MidspanThickness
        {
            get
            {
                return _midspanThickness;
            }
            set
            {
                if (value == _midspanThickness)
                    return;
                _midspanThickness = value;
                NotifyPropertyChanged(() => MidspanThickness);
            }
        }
        /// <summary>
        /// 净保护层
        /// </summary>
        public double NetProtectiveLayer
        {
            get
            {
                return _netProtectiveLayer;
            }
            set
            {
                if (value == _netProtectiveLayer)
                    return;
                _netProtectiveLayer = value;
                NotifyPropertyChanged(() => NetProtectiveLayer);
            }
        }
        /// <summary>
        /// 标准盖板模型
        /// </summary>
        public string StandardPlateModel
        {
            get
            {
                return _standardPlateModel;
            }
            set
            {
                if (value == _standardPlateModel)
                    return;
                _standardPlateModel = value;
                NotifyPropertyChanged(() => StandardPlateModel);
            }
        }
        /// <summary>
        /// 单元库名称
        /// </summary>
        public string CellName
        {
            get
            {
                return _cellName;
            }
            set
            {
                if (value == _cellName)
                    return;
                _cellName = value;
                NotifyPropertyChanged(() => CellName);
            }
        }
    }
    /// <summary>
    /// 沉降缝参数
    /// </summary>
    public class SettlementJoint : MyNotifyPropertyChanged
    {

        private string _fillMaterial;

        private string _mainWrappingMaterial;

        private string _internalPacking;

        private string _upperProtectiveLayer;
        public SettlementJoint()
        {
        }
        public SettlementJoint(string fillMaterial, string mainWrappingMaterial, string internalPacking, string upperProtectiveLayer)
        {
            FillMaterial = fillMaterial;
            MainWrappingMaterial = mainWrappingMaterial;
            InternalPacking = internalPacking;
            UpperProtectiveLayer = upperProtectiveLayer;
        }
        /// <summary>
        /// 沉降缝填充材料
        /// </summary>
        public string FillMaterial
        {
            get
            {
                return _fillMaterial;
            }
            set
            {
                if (value == _fillMaterial)
                    return;
                _fillMaterial = value;
                NotifyPropertyChanged(() => FillMaterial);
            }
        }
        /// <summary>
        /// 沉降缝包裹主材料
        /// </summary>
        public string MainWrappingMaterial
        {
            get
            {
                return _mainWrappingMaterial;
            }
            set
            {
                if (value == _mainWrappingMaterial)
                    return;
                _mainWrappingMaterial = value;
                NotifyPropertyChanged(() => MainWrappingMaterial);
            }
        }
        /// <summary>
        /// 沉降缝内部填塞
        /// </summary>
        public string InternalPacking
        {
            get
            {
                return _internalPacking;
            }
            set
            {
                if (value == _internalPacking)
                    return;
                _internalPacking = value;
                NotifyPropertyChanged(() => InternalPacking);
            }
        }
        /// <summary>
        /// 沉降缝上部保护层
        /// </summary>
        public string UpperProtectiveLayer
        {
            get
            {
                return _upperProtectiveLayer;
            }
            set
            {
                if (value == _upperProtectiveLayer)
                    return;
                _upperProtectiveLayer = value;
                NotifyPropertyChanged(() => UpperProtectiveLayer);
            }
        }
    }
    /// <summary>
    /// 左侧斜盖板
    /// </summary>
    public class LeftInclinedPlate : MyNotifyPropertyChanged
    {
        private double _length;
        private double _shortSideLength;
        private double _longSideLength;
        private double _thickness;
        private double _netProtectiveLayer;
        private string _standardPlateModel;
        private string _cellName;
        public LeftInclinedPlate()
        {
        }
        public LeftInclinedPlate(double length, double shortSideLength, double longSideLength, double thickness, double netProtectiveLayer, string standardPlateModel, string cellName)
        {
            Length = length;
            ShortSideLength = shortSideLength;
            LongSideLength = longSideLength;
            Thickness = thickness;
            NetProtectiveLayer = netProtectiveLayer;
            StandardPlateModel = standardPlateModel;
            CellName = cellName;
        }

        /// <summary>
        /// 板长L1(cm)
        /// </summary>
        public double Length
        {
            get
            {
                return _length;
            }
            set
            {
                if (value == _length)
                    return;
                _length = value;
                NotifyPropertyChanged(() => Length);
            }
        }

        /// <summary>
        /// 短边长度B1(cm)
        /// </summary>
        public double ShortSideLength
        {
            get
            {
                return _shortSideLength;
            }
            set
            {
                if (value == _shortSideLength)
                    return;
                _shortSideLength = value;
                NotifyPropertyChanged(() => ShortSideLength);
            }
        }

        /// <summary>
        /// 长边长度B2(cm)
        /// </summary>
        public double LongSideLength
        {
            get
            {
                return _longSideLength;
            }
            set
            {
                if (value == _longSideLength)
                    return;
                _longSideLength = value;
                NotifyPropertyChanged(() => LongSideLength);
            }
        }
        /// <summary>
        /// 盖板厚d1(cm)
        /// </summary>
        public double Thickness
        {
            get
            {
                return _thickness;
            }
            set
            {
                if (value == _thickness)
                    return;
                _thickness = value;
                NotifyPropertyChanged(() => Thickness);
            }
        }
        /// <summary>
        /// 净保护层(cm)
        /// </summary>
        public double NetProtectiveLayer
        {
            get
            {
                return _netProtectiveLayer;
            }
            set
            {
                if (value == _netProtectiveLayer)
                    return;
                _netProtectiveLayer = value;
                NotifyPropertyChanged(() => NetProtectiveLayer);
            }
        }
        /// <summary>
        /// 标准盖板模型
        /// </summary>
        public string StandardPlateModel
        {
            get
            {
                return _standardPlateModel;
            }
            set
            {
                if (value == _standardPlateModel)
                    return;
                _standardPlateModel = value;
                NotifyPropertyChanged(() => StandardPlateModel);
            }
        }
        /// <summary>
        /// 单元库名称
        /// </summary>
        public string CellName
        {
            get
            {
                return _cellName;
            }
            set
            {
                if (value == _cellName)
                    return;
                _cellName = value;
                NotifyPropertyChanged(() => CellName);
            }
        }
    }
    /// <summary>
    /// 右侧斜盖板
    /// </summary>
    public class RightInclinedPlate : MyNotifyPropertyChanged
    {
        private double _length;
        private double _shortSideLength;
        private double _longSideLength;
        private double _thickness;
        private double _netProtectiveLayer;
        private string _standardPlateModel;
        private string _cellName;

        public RightInclinedPlate()
        {
        }

        public RightInclinedPlate(double length, double shortSideLength, double longSideLength, double thickness, double netProtectiveLayer, string standardPlateModel, string cellName)
        {
            Length = length;
            ShortSideLength = shortSideLength;
            LongSideLength = longSideLength;
            Thickness = thickness;
            NetProtectiveLayer = netProtectiveLayer;
            StandardPlateModel = standardPlateModel;
            CellName = cellName;
        }

        /// <summary>
        /// 板长L1(cm)
        /// </summary>
        public double Length
        {
            get
            {
                return _length;
            }
            set
            {
                if (value == _length)
                    return;
                _length = value;
                NotifyPropertyChanged(() => Length);
            }
        }

        /// <summary>
        /// 短边长度B1(cm)
        /// </summary>
        public double ShortSideLength
        {
            get
            {
                return _shortSideLength;
            }
            set
            {
                if (value == _shortSideLength)
                    return;
                _shortSideLength = value;
                NotifyPropertyChanged(() => ShortSideLength);
            }
        }

        /// <summary>
        /// 长边长度B2(cm)
        /// </summary>
        public double LongSideLength
        {
            get
            {
                return _longSideLength;
            }
            set
            {
                if (value == _longSideLength)
                    return;
                _longSideLength = value;
                NotifyPropertyChanged(() => LongSideLength);
            }
        }
        /// <summary>
        /// 盖板厚d1(cm)
        /// </summary>
        public double Thickness
        {
            get
            {
                return _thickness;
            }
            set
            {
                if (value == _thickness)
                    return;
                _thickness = value;
                NotifyPropertyChanged(() => Thickness);
            }
        }
        /// <summary>
        /// 净保护层(cm)
        /// </summary>
        public double NetProtectiveLayer
        {
            get
            {
                return _netProtectiveLayer;
            }
            set
            {
                if (value == _netProtectiveLayer)
                    return;
                _netProtectiveLayer = value;
                NotifyPropertyChanged(() => NetProtectiveLayer);
            }
        }
        /// <summary>
        /// 标准盖板模型
        /// </summary>
        public string StandardPlateModel
        {
            get
            {
                return _standardPlateModel;
            }
            set
            {
                if (value == _standardPlateModel)
                    return;
                _standardPlateModel = value;
                NotifyPropertyChanged(() => StandardPlateModel);
            }
        }
        /// <summary>
        /// 单元库名称
        /// </summary>
        public string CellName
        {
            get
            {
                return _cellName;
            }
            set
            {
                if (value == _cellName)
                    return;
                _cellName = value;
                NotifyPropertyChanged(() => CellName);
            }
        }
    }

}
